import { createRouter, createWebHistory } from 'vue-router'
import Layout from "@/Layout/Layout";

const routes = [
  {
    path: '/',
    name: 'Layout',
    component: Layout,
    redirect:"/Home",
    children:[
      {
        path:"Home",
        name:"Home",
        component:()=>import ("@/views/HomeView")
      },
      {
        path: '/WebPage1',
        name: 'Webpage1',
        component: ()=>import("@/views/WebPage1")
      },
      {
        path: '/WebPage2',
        name: 'Webpage2',
        component: ()=>import("@/views/WebPage2")
      },
      {
        path: '/WebPage3',
        name: 'Webpage3',
        component: ()=>import("@/views/WebPage3")
      },
      {
        path: '/WebPage4',
        name: 'Webpage4',
        component: ()=>import("@/views/WebPage4")
      },
      {
        path: '/WebPage3_1',
        name: 'Webpage3_1',
        component: ()=>import("@/views/WebPage3_1")
      },

      {
        path: '/WebPage4_1',
        name: 'Webpage4_1',
        component: ()=>import("@/views/WebPage4_1")
      },
      {
        path: '/UserMsg',
        name: 'UserMsg',
        component: ()=>import("@/views/UserMsg"),
      },
      {
        path: '/StyleChange',
        name: 'StyleChange',
        component: ()=>import("@/views/StyleChange")
      },
    ]
  },
  {
    path: '/Login',
    name: 'Login',
    component: ()=>import("@/views/Login")
  },
  {
    path: '/Register',
    name: 'Register',
    component: ()=>import("@/views/Register")
  },

  // {
  //   path: '/About',
  //   name: 'About',
  //   component: ()=>import("@/views/AboutView")
  // },
]

const router = createRouter({
  history: createWebHistory(process.env.BASE_URL),
  routes
})

export default router
